import psutil

# partition = psutil.disk_partitions()
# for partition in partition:
#     print("分区", partition)

# disk_usage = psutil.disk_usage('/')
# print(f"磁盘使用情况：总容量{disk_usage.total/(1024**3):.2f}GB",
#       f""f"已用{disk_usage.used/(1024**3):.2f}GB,"
#       f"可用{disk_usage.free/(1024**3):.2f}GB"
#       )
# 磁盘读取次数
disk_io = psutil.disk_io_counters()
print(f"读取次数:{disk_io.read_count},"
      f"写入次数:{disk_io.write_count}")

